
<div class="hd">  
	<div class="hd_content"  >
 
	<span id="ugrop" > 权限用户组 </span> </div>
</div>
<div class="container" id="groupSource">
	<div class="con_view">
		<div class='nav_g_title'>
			<a href="#" tar="userdep" class="active">设备<span id="udepcount">(0)</span></a><a
				href="#" tar="userlist">用户<span id="ucount">(0)</span></a>
		</div>
		<div class='nav_items_lay'>
			<div class='nav_items panel  scroll  imglist' id="userdep"></div>
			<div class='nav_items panel  scroll' id="userlist" style='display: none'>
			</div>
		</div>
	</div>
</div>
<style>
 
.nav_g_title {
	height: 35px;
	box-shadow: 1px 1px 2px #FFF;
	background: rgba(0, 0, 0, 0.23);
	display: -moz-box;
	display: -webkit-box;
	display: box;
	line-height: 35px;
}

.nav_g_title a {
	display: block;
	text-align: center;
	-moz-box-flex: 1;
	-webkit-box-flex: 1;
	box-flex: 1;
	 background: linear-gradient(to top, rgba(0, 0, 0, 0.44) 40%,
		rgba(0, 0, 0, 0) 65%);
 
}

#groupSource  .nav_g_title a:first-child {
	border-right: 1px solid #fff;
}

#groupSource  .nav_g_title a:last-child {
	border-left: 1px solid #000;
	
}

#groupSource  .nav_g_title a.active {
	background: none;
}

#groupSource  .nav_items input {
	display: none;
}

.panel .items .item {
	height: 30px;
	line-height: 30px;
	border-bottom: 1px solid #FFF;
	cursor: pointer;
	padding: 5px;
}

.panel .items .item>img {
	float: left;
}
.panel .items .item>span {
    line-height: 30px;
    height: 30px;
    overflow: hidden;
        display: inline-block;
    height: 100%;
    margin-left: 5px;
    }
 #userdep .level_2.select{
    background:rgba(0,0,0,0.4);
 } 
  #userdep .level_2 .name{  
    display: inline-block;
    width: 100%;
    }
  #userdep .level_2 .name:after {
	content: "\f105";
 
	float: right;
	margin-top: 5px;
	background-color: rgba(255, 254, 254, 0.42);
	width: 24px;
	height: 24px;
	line-height: 26px;
	margin-right: 10px;
	border-radius: 30px;
	color: rgb(241, 241, 241);
	text-align: center;
	font-size:24px;
}
  #userdep.videolist .level_2 .name::before{
    content: "\f03d";
    float: left;
	margin-top: 5px;
	background-color: rgba(255, 254, 254, 0.42);
	width: 24px;
	height: 24px;
	line-height: 26px;
	margin-right: 10px;
	border-radius: 30px;
	 
	text-align: center;
	font-size:18px;
 }
 #userdep.imglist .level_2 .name::before{
   content: "\f03e";
    float: left;
	margin-top: 5px;
	background-color: rgba(255, 254, 254, 0.42);
	width: 24px;
	height: 24px;
	line-height: 26px;
	margin-right: 10px;
	border-radius: 30px;
 
	text-align: center;
	font-size:18px;
 }
.admin_true #userdep  .online_0 .name::before{
   
    color:rgba(0, 0, 0, 0.5)
}
.admin_false #userdep  .online_0 .name::before{
   
    color:lime
}
#userdep  .online_1 .name::before{
    
    color:lime;  
}
.dweather{display:none}

</style>
<script>

  $("#groupSource .nav_g_title a").on("click",function(){
	$("#groupSource .nav_g_title a").removeClass("active");
    $(this).addClass("active");
    $("#groupSource .nav_items").hide();
    $("#"+$(this).attr("tar")).show();
	return false;
});  
//加载图片 a 有个默认事件 click 这里忽略
/* $("body").on(
		"click",
		"#userdep .level_2 .name",
		function(e) {
	    alert("ok")
		//return false;
		}); */
// 加载图片
  $("body").on(
		"tap",
		"#userdep .level_2 .name",
		function(e) {
			showLoadingToast(true);
			toNextPageWhenClick();
			
			var _this = $(this).parent();
			
			$("#userdep .level_2").removeClass("select");
			
			_this.addClass("select");
			
           var curr_equip=$(".curr_equip");
           curr_equip.html(_this.find(".name span").html());
 
			/////////
			G_PUID= _this.attr("puid");
			curr_equip.attr("puid",G_PUID);
		 
			 

			var src=CONETXT_PATH+"/equip/{type}/{puid}.do".format({"puid":G_PUID,"type":G_TYPE}); 
			 //加载天气数据
			 {
				   var _areaname=_this.find(".gprovince").val() ;
			 
					var wdata=provinceWeather[_areaname];
				    if((wdata!=null)&&(wdata.result!=null)){
				    	 
							   $("#weather_tool").show();
					    	   $("#weather_tool").attr("class"," eqp_weather weath_icon   png30 d"+wdata.result.data.realtime.weather.img);
						      
						       updateWeatherForm(wdata);
						       $("#weather_tool").show();
					    	 	
				    }else{
				    	 $("#weather_tool").hide();
				    }
					 
				   
			 }
			 
			 
            
		   $("#small_area").load(src, function() {
				//切换到下一页
				// swiper.slideTo(2, 500, false);
				 lazyLoadPic(".img_content");
				 showLoadingToast(false);
  
			}); 
            
			// 
 
		 	 
		});  
		

</script>
